import React from 'react';
import {createRoot} from 'react-dom/client';
import {Provider} from 'react-redux';
import {store} from '@store/index';

import './index.css';
import App from './App';

import reportWebVitals from './reportWebVitals';
import {APP_TITLE} from '@configs';
import {BrowserRouter} from 'react-router-dom';

const container = document.getElementById('root')!;
const root = createRoot(container);

document.title = APP_TITLE as string;

root.render(
    <React.StrictMode>
        <Provider store={store}>
            <BrowserRouter>
                <App />
            </BrowserRouter>
        </Provider>
    </React.StrictMode>,
);

reportWebVitals();
